﻿<Window x:Class="IUExample.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:components="clr-namespace:Mnk.Library.WpfControls.Components;assembly=Mnk.Library.WpfControls"
        xmlns:captioned="clr-namespace:Mnk.Library.WpfControls.Components.Captioned;assembly=Mnk.Library.WpfControls"
        xmlns:filesAndFolders="clr-namespace:Mnk.Library.WpfControls.Components.FilesAndFolders;assembly=Mnk.Library.WpfControls"
        xmlns:dropDown="clr-namespace:Mnk.Library.WpfControls.Components.DropDown;assembly=Mnk.Library.WpfControls"
        xmlns:wpfSyntaxHighlighter="clr-namespace:Mnk.Library.WpfSyntaxHighlighter;assembly=Mnk.Library.WpfSyntaxHighlighter"
        xmlns:units="clr-namespace:Mnk.Library.WpfControls.Components.Units;assembly=Mnk.Library.WpfControls"
        Title="UI.Examples" 
        MinHeight="525" MinWidth="525"
        Height="525" Width="525">
    <TabControl Margin="5">
        <TabItem Header="WpfControls">
            <TabControl Margin="5">
                <TabItem Header="Simple Components">
                    <ScrollViewer VerticalScrollBarVisibility="Auto">
                        <StackPanel >
                            <GroupBox Header="NumericUpDown" Margin="5">
                                <dropDown:NumericUpDown Minimum="1" Maximum="32" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="DoubleUpDown" Margin="5">
                                <dropDown:DoubleUpDown Minimum="1" Maximum="32" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="TimeBox" Margin="5">
                                <dropDown:TimeBox Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="ExtCheckBox" Margin="5">
                                <components:ExtCheckBox Content="ExtCheckBox" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="FlagsCheckBoxes" Margin="5">
                                <components:FlagsCheckBoxes Name="FlagsCheckBoxes" Caption="FlagsCheckBoxes" Value="1" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="HotkeyBox" Margin="5">
                                <components:HotkeyBox  Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="AutoCompoBox" Margin="5">
                                <components:AutoComboBox Name="AutoComboBox" IsEditable="True" AutoSort="True" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="EditPath-File" Margin="5">
                                <filesAndFolders:EditPath PathGetterType="File" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="EditPath-Folder" Margin="5">
                                <filesAndFolders:EditPath PathGetterType="Folder" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="EditPath-CustomFilter" Margin="5">
                                <filesAndFolders:EditPath PathGetterType="File" PathGetterFilter="My files *.my|*.my" Margin="5"/>
                            </GroupBox>
                        </StackPanel>
                    </ScrollViewer>
                </TabItem>
                <TabItem Header="Captioned Components">
                    <ScrollViewer VerticalScrollBarVisibility="Auto">
                        <StackPanel >
                            <captioned:CaptionedComboBox Name="CaptionedComboBox" Caption="CaptionedComboBox" Margin="5"/>
                            <captioned:CaptionedDatePicker Caption="CaptionedDatePicker" Margin="5"/>
                            <captioned:CaptionedEditPath Caption="CaptionedEditPath-File" PathGetterType="File" Margin="5"/>
                            <captioned:CaptionedEditPath Caption="CaptionedEditPath-Folder" PathGetterType="Folder" Margin="5"/>
                            <captioned:CaptionedNumericUpDown Caption="CaptionedNumericUpDown" Minimum="1" Maximum="16" Margin="5"/>
                            <DockPanel>
                            <CheckBox Content="Is readonly" DockPanel.Dock="Right" VerticalAlignment="Center" Margin="5" Name="IsReadOnly" IsChecked="True"/>
                            <captioned:CaptionedPasswordBox Caption="CaptionedPasswordBox" Value="Test" Margin="5" IsReadOnly="{Binding ElementName=IsReadOnly, Path=IsChecked}"/>
                            </DockPanel>
                            <captioned:CaptionedTextBox Caption="CaptionedTextBox" Margin="5"/>
                            <captioned:CaptionedTimeBox Caption="CaptionedTimeBox" Margin="5"/>
                        </StackPanel>
                    </ScrollViewer>
                </TabItem>
                <TabItem Header="ListBoxes">
                    <ScrollViewer VerticalScrollBarVisibility="Auto">
                        <StackPanel >
                            <GroupBox Header="ExtListBox" Margin="5">
                                <components:ExtListBox Name="ExtListBox" AllowDrop="True" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableListBox" Margin="5">
                                <components:CheckableListBox Name="CheckableListBox" AllowDrop="True" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableFileListBox-File" Margin="5">
                                <components:CheckableFileListBox Name="CheckableFileListBox" PathGetterType="File" AllowDrop="True" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableFileListBox-Folder" Margin="5">
                                <components:CheckableFileListBox Name="CheckableFolderListBox1" PathGetterType="Folder" AllowDrop="True" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableFileListBox-CustomFilter" Margin="5">
                                <components:CheckableFileListBox Name="CheckableFolderListBox2" PathGetterType="Folder" PathGetterFilter="My Files(*.my)|*.my" AllowDrop="True" Margin="5"/>
                            </GroupBox>
                        </StackPanel>
                    </ScrollViewer>
                </TabItem>
                <TabItem Header="Units">
                    <ScrollViewer VerticalScrollBarVisibility="Auto">
                        <StackPanel >
                            <GroupBox Header="ComboBoxUnit-Text" Margin="5">
                                <units:ComboBoxUnit Name="ComboBoxUnit" UnitType="Text" Title="Test" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="ListBoxUnit-Text" Margin="5">
                                <units:ListBoxUnit Name="ListBoxUnit" UnitType="Text" Title="Test" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableListBoxUnit-File" Margin="5">
                                <units:CheckableListBoxUnit Name="CheckableListBoxUnit" UnitType="FilePath" Title="Test" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="CheckableFileListBoxUnit" Margin="5">
                                <units:CheckableFileListBoxUnit Name="CheckableFileListBoxUnit" UnitType="FilePath" Title="Test" Margin="5"/>
                            </GroupBox>
                            <GroupBox Header="ListBoxUnit-Text-FixedSize" Margin="5">
                                <DockPanel>
                                    <CheckBox Content="Is readonly" DockPanel.Dock="Top" VerticalAlignment="Center" Margin="5" Name="IsReadOnlyLB" IsChecked="True" />
                                    <units:ListBoxUnit Name="ListBoxUnitFixedSize" UnitType="Text" Title="Test" Margin="5" Height="100">
                                        <units:ListBoxUnit.ItemTemplate>
                                            <DataTemplate>
                                                <StackPanel>
                                                    <captioned:CaptionedPasswordBox IsReadOnly="{Binding Source={x:Reference IsReadOnlyLB}, Path=IsChecked}" Margin="5" VerticalAlignment="Stretch" />
                                                </StackPanel>
                                            </DataTemplate>
                                        </units:ListBoxUnit.ItemTemplate>
                                    </units:ListBoxUnit>
                                </DockPanel>
                            </GroupBox>
                        </StackPanel>
                    </ScrollViewer>
                </TabItem>
            </TabControl>
        </TabItem>
        <TabItem Header="WPFSyntaxHighlighter">
            <TabControl Margin="5">
                <TabItem Header="SyntaxHighlighter">
                    <DockPanel>
                        <TextBox Name="shText" TextChanged="ShText_OnTextChanged" DockPanel.Dock="Top"/>
                        <wpfSyntaxHighlighter:SyntaxHighlighter x:Name="Highlighter"/>
                    </DockPanel>
                </TabItem>
            </TabControl>
        </TabItem>
    </TabControl>
</Window>
